var commonModule = angular.module('commonModule');
commonModule.directive('scroller', function() {

    var scrollerFun = function(scope, elem, attrs) {

        var myScroll = new iScroll($(elem).attr('id'), {
            useTransition: true,
            hideScrollbar: false,
        });
            

    };

    document.addEventListener('touchmove', function(e) {
        e.preventDefault();
    }, false);

    return {
        restrict: 'A',
        replace: true,
        link: scrollerFun
    };
});
